package com.uzai.console.service.qiniu;

import com.uzai.console.dto.qiniu.QiniuConfigDto;
import com.uzai.console.entity.Qiniu;
import com.uzai.console.vo.qiniu.QiniuConfig;
import com.uzai.console.vo.qiniu.QiniuConfigInfoVo;
import org.springframework.web.multipart.MultipartFile;

import java.io.InputStream;

/**
 * @author jianghan
 * @date 2019-06-18 15:06
 */
public interface QiniuService {
    String upload(Long merId, InputStream inputStream, String fileName);

    /**
     * 获取七牛云配置
     * @author liuqi
     * @date 2022/1/18 15:17
     * @param merId
     */
    Qiniu getQiniuByMerId(Long merId);

    Boolean checkConfig(QiniuConfigDto qiniuConfigDto);

    void addQiniuConfig(QiniuConfigDto qiniuConfigDto);

    /**
     * 上传文件
     * @author liuqi
     * @date 2022/1/18 15:17
     * @param file
     */
    String uploadFile(MultipartFile file, Long merId);

    /**
     * 查询七牛云详情
     * @author jitwxs
     * @date 2022/1/18 17:25
     * @param merId
     * @return com.uzai.console.vo.qiniu.QiniuConfigVo
     */
    QiniuConfigInfoVo findQiniuConfigInfo(Long merId);

}
